﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace WiTeach.Tools
{
    public class BaseDAL
    {
        /// <summary>
        /// 获取表数据条数
        /// </summary>
        /// <param name="tableName"></param>
        /// <returns></returns>
        public static int getTotalCount(string tableName)
        {
            string strSql = "select count(*) from " + tableName;
            object res = SqlHelper.ExecuteScalar(strSql);
            return Convert.ToInt32(res);
        }
    }
}
